<script>
import DataShowTable from './DataShowTable.vue';
export default {
    data() {
        return {
            roles: [
                { name: '管理员', permissions: 0 },
                { name: '经理', permissions: 1 },

            ]
        }
    },
    components: {
        DataShowTable
    },
    methods: {
        handleInsert(event) {
            alert("insert")
        }
    }
}
</script>

<template>
    <!-- <div v-for="role in roles">
        <span>{{ role.name }}</span>
        <span>{{ role.permissions }}</span>
    </div> -->
    <div>
        <el-button link type="primary" size="small" @click="handleInsert">添加</el-button>
    </div>
    <DataShowTable :roles="this.roles" />
</template>